<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <script src="../../vue.js"></script>
</head>
<body>
<div id="app">
    <input v-model="message1" placeholder="rollingball">
    <div>{{message1}}</div>

    <textarea v-model="message2" cols="30" rows="10"></textarea>
    <div>{{message2}}</div>

    <select v-model="message3">
        <option>1998</option>
        <option>1999</option>
        <option>2021</option>
    </select>

    <input type="checkbox" id="check1" value="js" v-model="message4">js
    <!-- <label for="js">js</label> -->
    <input type="checkbox" id="check2" value="vue" v-model="message4">vue
    <!-- <label for="vue">vue</label> -->
    <input type="checkbox" id="check3" value="nodejs" v-model="message4">nodejs
    <!-- <label for="nodejs">nodejs</label> -->
    <div>选中：{{message4}}</div>

    <input type="radio" id="vue" value="vue" v-model="message5">vue
    <input type="radio" id="nodejs" value="nodejs" v-model="message5">nodejs
    <div>选中：{{message5}}</div>

    <button @click="submit">提交</button>
</div>
    
<script>
    var app = new Vue({
        el: "#app",
        data: {
            message1: "bollu",
            message2: "rollingball",
            message3: "1999",
            message4: ["vue"],
            message5: "vue"
        },
        methods: {
            submit: function(){
                console.log(this.message1);
                console.log(this.message2);
                console.log(this.message3);
                console.log(this.message4);
                console.log(this.message5);
            }
        }
    })
</script>
</body>
</html>